<include file="Public/header" />
<include file="Public/menu" />

<!-- 内容页 -->
<div class="content-wrapper">
    <!-- 面包屑 -->
    <section class="content-header">
        <h1>
            店铺配置
            <small>管理</small>
        </h1>
        <ol class="breadcrumb">
            <li><a href="#"><i class="fa fa-dashboard"></i> 店铺配置</a></li>
            <li class="active">店铺运费模板</li>
        </ol>
    </section>

    <!-- 内容 -->
    <section class="content"><div class="row"><div class="col-md-12">
        <div class="box box-info">
            <div class="box-header with-border">
                <h3 class="box-title">店铺运费模板</h3>
            </div>
            <!-- /.box-header -->
            <!-- form start -->
            <form id="form" action="" method="post" accept-charset="UTF-8" class="form-horizontal" pjax-container="">
                <div class="box-body">
                    <div class="form-group 1">
                        <label class="col-sm-2 control-label">首重</label>
                        <div class="col-sm-6">
                            <div class="input-group">
                                <span class="input-group-addon"><i class="fa fa-pencil"></i></span>
                                <input type="test" name="firstunit" value="{$dlyyctmp.firstunit}" class="form-control" placeholder="首重">
                                <span class="input-group-addon">Kg</span>
                            </div>
                        </div>
                    </div>
                    <div class="form-group 1">
                        <label class="col-sm-2 control-label">首重运费</label>
                        <div class="col-sm-6">
                            <div class="input-group">
                                <span class="input-group-addon"><i class="fa fa-pencil"></i></span>
                                <input type="test" name="firstprice" value="{$dlyyctmp.firstprice}" class="form-control" placeholder="首重运费">
                                <span class="input-group-addon">元</span>
                            </div>
                        </div>
                    </div>
                    <div class="form-group 1">
                        <label class="col-sm-2 control-label">续重</label>
                        <div class="col-sm-6">
                            <div class="input-group">
                                <span class="input-group-addon"><i class="fa fa-pencil"></i></span>
                                <input type="test" name="continueunit" value="{$dlyyctmp.continueunit}" class="form-control" placeholder="续重">
                                <span class="input-group-addon">Kg</span>
                            </div>
                        </div>
                    </div>
                    <div class="form-group 1">
                        <label class="col-sm-2 control-label">续重费</label>
                        <div class="col-sm-6">
                            <div class="input-group">
                                <span class="input-group-addon"><i class="fa fa-pencil"></i></span>
                                <input type="test" name="continueprice" value="{$dlyyctmp.continueprice}" class="form-control" placeholder="首重运费">
                                <span class="input-group-addon">元</span>
                            </div>
                        </div>
                    </div>
                    <if condition="$dlyyctmp['is_byself'] eq 1">
                    <div class="form-group 1">
                        <label class="col-sm-2 control-label">周边配送物流名称</label>
                        <div class="col-sm-6">
                            <div class="input-group">
                                <span class="input-group-addon"><i class="fa fa-pencil"></i></span>
                                <input type="test" name="myexpress" value="{$dlyyctmp.myexpress}" class="form-control" placeholder="周边配送物流名称,例如怡臣速配">
                            </div>
                        </div>
                    </div>
                    </if>

                </div>
                <!-- /.box-body -->
                <div class="box-footer">
                    <div class="col-sm-2">

                    </div>
                    <div class="col-sm-6">
                        
                        <div class="btn-group pull-right">
                            <button type="submit" class="btn btn-info pull-right">提交</button>
                        </div>

                    </div>

                </div>
                <!-- /.box-footer -->
            </form>
        </div>

    </div></div>

    </section>
</div>
<!-- 底部 -->
<include file="Public/common_footer" />
<script type="text/javascript">
    //表单验证
    $("#form").validate({
        rules: {
            type_name:{
                required: true,
				rangelength: [2, 50]
            },
            firstunit:{
                required: true,
				isPrice: true,
				min:0.01
            },
            firstprice:{
                required: true,
				isPrice: true,
				min:0.01
            },
            continueunit:{
                required: true,
				isPrice: true,
				min:0.01
            },
            continueprice:{
                required: true,
				isPrice: true,
				min:0.01
            }
        },
        messages:{
            type_name: {
                required: "请输入运费模板名称"
            },
            firstunit: {
                required: "请输入首重"
            },
            firstprice: {
                required: "请输入首重运费"
            },
            continueunit: {
                required: "请输入续重"
            },
            continueprice: {
                required: "请输入续重费"
            }
        },
        submitHandler: function(form){
            form.submit();   //提交表单
        }
    });
</script>

